package se.webbzon.boltzmann.player;

import se.webbzon.boltzmann.battle.battleaction.punch.PunchActionFactory;
import se.webbzon.boltzmann.game.character.CharacterException;
import se.webbzon.boltzmann.game.object.player.AbstractPlayerCharacter;
import se.webbzon.boltzmann.game.object.player.boltzmann.BoltzmannPlayerCharacter;

public class BoltzmannCharacter extends PlayerCharacter {
	
	// The singleton instance
	private static BoltzmannCharacter singleton;
	
	/*============================================================
	Constructors
	============================================================*/

	private BoltzmannCharacter() {
		super("Boltzmann", "boltzmann");
		addBattleActionFactory(new PunchActionFactory());
	}
	
	/*============================================================
	Public Methods
	============================================================*/
	
	@Override public AbstractPlayerCharacter makePlayerCharacter(Player player) throws CharacterException {
		return new BoltzmannPlayerCharacter(player,this);
	}

	/** Returns the singleton instance of this player character. **/
	public static BoltzmannCharacter instance() {
		if (singleton == null) {
			singleton = new BoltzmannCharacter();
		}
		return singleton;
	}

}
